<template>
    <div>
        <div v-for="student  in  students" class="student">
            <h3>学生信息展示</h3>
            <p>学生姓名:{{student.name}}</p>
            <p>学生年龄:{{student.age}}</p>
            <p>学生专业:{{student.major}}</p>
        </div>
    </div>
</template>


<script>

    export default {
        name: 'Student',
        data() {
            return {
                students: [
                    {
                        name: 'tom',
                        age: 20,
                        major: 'Java'
                    },
                    {
                        name: 'jack',
                        age: 30,
                        major: 'Web'
                    }
                ]
            }
        }
    }

</script>


<style scoped>
    .student {
        border: 1px solid red;
        width: 300px;
        height: 200px;
        text-align: center;
        margin-top: 10px;
    }
</style>
